class Master(object):
    def __init__(self):
        self.kongfu = "古法的煎饼果子配方"

    def make_cake(self):
        print("[古法]按照<%s>制作了一份煎饼果子"%self.kongfu)


class School(object):
    def __init__(self):
        self.kongfu = "现代的煎饼果子配方"

    def make_cake(self):
        print("[现代]按照<%s>制作了一份煎饼果子"%self.kongfu)


class Prentice(School, Master):
    def __init__(self):
        self.kongfu = "猫氏煎饼果子配方"
        self.__money = 1000

    def __print_info(self):
        print(self.kongfu)
        print(self.__money)

    def set_money(self, num):
        self.__money = num

    def get_money(self):
        return self.__money


class PrenticePrentice(Prentice):
    pass


p = Prentice()
# 对象不能访问私有属性和方法
# print(p.__money)
# p.__print_info()
print(p.get_money())
p.set_money(8000)
print(p.get_money())


pp = PrenticePrentice()
# 子类不能继承父类的私有属性和方法
# print(pp.__money)
# pp.__print_info()
